﻿@model IEnumerable<TaoNiuOA.Models.Department>
@{
    ViewBag.Title = "部门管理";
    Layout = "~/Views/Shared/_AdminLayout.cshtml";
}
<fieldset>
    <legend>部门管理 | <a href="../UserGroup/index">职位管理</a></legend>
    <p>
        @Html.ActionLink("添加部门", "Create")
    </p>
    <table>
        <tr>
            <th>
                部门名称
            </th>
            <th>
                排序
            </th>
            <th>
                操作
            </th>
        </tr>
        @foreach (var item in Model)
        {
            <tr>
                <td>
                    @Html.DisplayFor(modelItem => item.Name)
                </td>
                <td>
                    @Html.DisplayFor(modelItem => item.Sort)
                </td>
                <td>
                    @Html.ActionLink("编辑", "Edit", new { id = item.DepartmentID }) |
                    @Html.ActionLink("删除", "Delete", new { id = item.DepartmentID })
                </td>
            </tr>
        }
    </table>
</fieldset>
